<?php
namespace app\admin\controller;
use think\Db;
use think\Session;
use think\Request;

class Index extends Admincontroller
{
	/**
	 * 后台首页视图加载
	 * @return [type] [description]
	 */
	public function index()
	{
		// 通过session 值 查询 用户昵称
		$name = Db::name('admin')->field('name')->where('name = "'.Session::get('admin').'"')->find();
    	return $this->fetch('index',['title'=>'蒸汽男孩后台','nick'=>$name['name']]);
	}
}